<script setup lang="ts">
    import Header from './Header.vue'
    import { ref } from 'vue'

    const showDate = ref<string>('today')
    const getShowDate = (key: string) => {
        showDate.value = key
    }
</script>

<template>
    <Header :getShowDate="getShowDate" />
    <div class="content">
        <router-view v-slot="{ Component, route }">
            <component
                :is="Component"
                v-bind="route.name === 'ZheBaMap' ? { showDate } : {}"
            />
        </router-view>
    </div>
</template>
<style scoped lang="less">
    .content {
        width: 100vw;
        height: calc(100vh - 64px);
    }
</style>
